<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<script>
  async function fn(){
    try{
      const result = await new Promise((resolve,reject)=>{
        throw ('异常')
      })

      console.log(result)
    }catch (err){
      console.log(err)
    }
  }

  fn();
</script>
</body>
</html>